package ch.trainingtest.service.implement;

import java.util.List;

import javax.ejb.EJB;
import javax.ejb.Stateless;
import javax.jws.WebService;

import ch.trainingtest.business.UserManagementBean;
import ch.trainingtest.dto.UserDto;
import ch.trainingtest.service.IUserManagementService;

@WebService(serviceName = "userManagementService", endpointInterface = "ch.trainingtest.service.IUserManagementService")
@Stateless
public class UserManagementService implements IUserManagementService{

	@EJB
	private UserManagementBean userManagementBean;
	

	public UserDto checkUserLogin(String username, String password) {
		return userManagementBean.checkUserLogin(username, password);
	}

	public void createUser(String username, String password) {
		userManagementBean.createUser(username, password);
		
	}

	public List<UserDto> getAllUsers() {
		return userManagementBean.getAllUsers();
	}

}
